package de.tudarmstadt.ukp.muip.fibqdojo;

import java.util.List;

import com.google.common.collect.Lists;

import de.tudarmstadt.ukp.muip.fibqdojo.interfaces.IFIBQSentence;
import de.tudarmstadt.ukp.muip.fibqdojo.interfaces.IFIBQSentenceToken;
import de.tudarmstadt.ukp.muip.fibqdojo.interfaces.IStructureVisitor;

public class Sentence implements IFIBQSentence {

    private List<IFIBQSentenceToken> tokens = Lists.newLinkedList();
    boolean hasMarkedTokens;

    public Sentence(IFIBQSentenceToken... sentenceTokens) {
        for (IFIBQSentenceToken token : sentenceTokens) {
            tokens.add(token);
        }
    }

    public List<IFIBQSentenceToken> getSentenceTokens() {
        return tokens;
    }

    @Override
    public boolean isMarked() {
        return hasMarkedTokens;
    }

    @Override
    public void setMarked(boolean marked) {
        hasMarkedTokens = marked;
    }

    public void accept(IStructureVisitor visitor) {
        visitor.visit(this);
    }

}
